package org.lds.hotkey.client.remote;

import org.lds.hotkey.common.model.dto.ResultDTO;
import org.lds.hotkey.common.util.RestUtil;
import org.lds.hotkey.console.remote.model.BatchReceiveHotkeyRequest;
import org.springframework.core.ParameterizedTypeReference;

public class Client {
    public static ResultDTO receiveHotkey(String address, BatchReceiveHotkeyRequest request) {
        String url = "http://" + address + "/api/remote/hotkey/receive";
        return RestUtil.post(url, request, new ParameterizedTypeReference<ResultDTO>() {});
    }
}
